﻿<UserControl x:Class="ViewParametrerGroupe"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:local="clr-namespace:OMANE.Modules.PMT"
             xml:lang="fr-FR"
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="600">
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*"/>
            <ColumnDefinition Width="5"/>
            <ColumnDefinition Width="*"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <GridSplitter HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Grid.Column="1" Grid.RowSpan="4" />

        <StackPanel Orientation="Horizontal" Grid.ColumnSpan="3" >
            <TextBlock Margin="5" Text="Groupe" />
            <ComboBox  Margin="5"  MinWidth="100" ItemsSource="{Binding Groupes}" SelectedItem="{Binding Path=Groupe, Mode=TwoWay}"/>
            <TextBlock  Margin="5" Text="Garantie"/>
            <ComboBox  Margin="5"  MinWidth="100" ItemsSource="{Binding Garanties}" SelectedItem="{Binding Path=Garantie, Mode=TwoWay}"/>
            <Button Content="Valider"  Margin="5"/>
        </StackPanel>

        <GroupBox Header="Commissions et Frais" Grid.Row="1"  >
            <local:AdvancedDatagrid x:Name="DgridComFrais" CanUserAddRows="False" CanUserDeleteRows="False" SelectionMode="Extended" SelectionUnit="CellOrRowHeader"  ItemsSource="{Binding TxComFrais}" ColumnWidth="*" AutoGeneratingColumn="AdvancedDatagrid_AutoGeneratingColumn" >
                <local:AdvancedDatagrid.ContextMenu>
                    <ContextMenu>
                        <MenuItem Header="Modifier Valeur" Click="Modifier_Valeur_MenuItem_ComFrais_Click"  />
                        <MenuItem Header="Copier" Click="Copier_MenuItem_ComFrais_Click" />
                        <MenuItem Header="Coller" Click="Coller_MenuItem_ComFrais_Click"/>
                        <MenuItem Header="Recalculer" Click="Recalculer_MenuItem_ComFrais_Click" />
                    </ContextMenu>
                </local:AdvancedDatagrid.ContextMenu>
            </local:AdvancedDatagrid>
        </GroupBox>
        <GroupBox Header="Reassurance" Grid.Row="2"  >
            <local:AdvancedDatagrid x:Name="DgridReass" CanUserAddRows="False" CanUserDeleteRows="False" ItemsSource="{Binding Reass}" ColumnWidth="*" SelectionMode="Extended" SelectionUnit="CellOrRowHeader" AutoGeneratingColumn="AdvancedDatagrid_AutoGeneratingColumn" >
                <local:AdvancedDatagrid.ContextMenu>
                    <ContextMenu>
                        <MenuItem Header="Modifier Valeur" Click="Modifier_Valeur_MenuItem_Reass_Click" />
                        <MenuItem Header="Copier" />
                        <MenuItem Header="Coller" />
                        <MenuItem Header="Recalculer" />

                    </ContextMenu>
                </local:AdvancedDatagrid.ContextMenu>
            </local:AdvancedDatagrid>
        </GroupBox>
        <GroupBox Header="Nouvelles Generation" Grid.Row="3" >
            <local:AdvancedDatagrid x:Name="DgridNvleGen" CanUserAddRows="False" CanUserDeleteRows="False" ItemsSource="{Binding NvleGen}" ColumnWidth="*" SelectionMode="Extended" SelectionUnit="CellOrRowHeader"  AutoGeneratingColumn="AdvancedDatagrid_AutoGeneratingColumn" >
                <local:AdvancedDatagrid.ContextMenu>
                    <ContextMenu>
                        <MenuItem Header="Modifier Valeur" Click="Modifier_Valeur_MenuItem_NvleGen_Click" />
                        <MenuItem Header="Copier" />
                        <MenuItem Header="Coller" />
                        <MenuItem Header="Recalculer" />

                    </ContextMenu>
                </local:AdvancedDatagrid.ContextMenu>
            </local:AdvancedDatagrid>
        </GroupBox>
        <GroupBox Header="Deroules" Grid.Row="1" Grid.Column="2" Grid.RowSpan="3"  >
            <local:AdvancedDatagrid x:Name="DgridDeroule" CanUserAddRows="False" CanUserDeleteRows="False"  ItemsSource="{Binding Deroule}" ColumnWidth="*" SelectionMode="Extended" SelectionUnit="CellOrRowHeader" AutoGeneratingColumn="AdvancedDatagrid_AutoGeneratingColumn"  >
                <local:AdvancedDatagrid.ContextMenu>
                    <ContextMenu>
                        <MenuItem Header="Modifier Valeur" Click="Modifier_Valeur_MenuItem_Deroule_Click" />
                        <MenuItem Header="Copier" />
                        <MenuItem Header="Coller" />
                        <MenuItem Header="Recalculer" />

                    </ContextMenu>
                </local:AdvancedDatagrid.ContextMenu>
            </local:AdvancedDatagrid>
        </GroupBox>

    </Grid>
</UserControl>
